<!--
 * @Author: your name
 * @Date: 2020-10-15 10:12:40
 * @LastEditTime: 2021-02-23 15:01:05
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \sende_nuxt\components\home\ShopNow.vue
-->
<template>
   <div class="ShopNow mb70">
        <div class="ShopNow_box relative" v-for="(item, index) of ShopNowData" :key="'item' + index">
            <div class="ShopNow_img">
                <img class="img" :src="item.img" alt="">
            </div>
            <div class="absolute our_pick_txt size17 b text_c c333 lh15" :style="istxt">{{item.txt}}</div>
            <nuxt-link class="ShopNow_link size16 b absolute" :to="item.route" :class="{ShopNow_btn:  !Object.keys(isClass).length }" :style="isClass">{{item.name}}</nuxt-link>
        </div>
   </div>
</template>

<script>
export default {
    props: {
        ShopNowData: {
            type: [Array, Object],
            default: () => []
        },
        isClass: {
            type: [Array, Object],
            default: () => []
        },
        istxt: {
            type: [Array, Object],
            default: () => []
        }
    }
}
</script>

<style lang="scss" scoped>
@import '~/assets/scss/index.scss';
.ShopNow {
    max-width:1200px;
    margin:0 auto;
    @include flex();
    justify-content: space-between;
    flex-wrap: wrap;
    &_box {
        width: 49%;
        position: relative;
        .ShopNow_btn {
            background: transparent;
            border: 1px solid $c333;
            &:hover {
                border: 1px solid $c666;
                color: $c666;
                // background: $theme1;
            }
        }
    }
    &_img {
        position: relative;
        padding-top: 68.03%;
        .img {
            position: absolute;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
        }
    }
    &_link {
        border: 1px solid $c333;
        &:hover {
            border: 1px solid $c666;
            color: $c666;
            // background: $theme1;
        }
    }
}
.ShopNow_btn {
    @include flex-center(center);
    position: absolute;
    left: 20px;
    bottom: 20px;
    width: 220px;
    height: 50px;
    color: $c333;
    border-radius: 5px;
    box-sizing: border-box;
}
.our_pick_txt {
    left: 20px;
    bottom: 80px;
    width: 220px;
}
</style>